home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c-part1 / 8243 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  1.6 KB

  1. Path: newshost.lanl.gov!tanmoy
  2. From: tanmoy@qcd.lanl.gov (Tanmoy Bhattacharya)
  3. Newsgroups: comp.lang.pl1,comp.lang.c
  4. Subject: Re: PL/I and C
  5. Date: 29 Feb 1996 17:11:49 GMT
  6. Organization: Los Alamos National Laboratory
  7. Message-ID: <TANMOY.96Feb29101149@qcd.lanl.gov>
  8. References: <4gh5ru$eng@goanna.cs.rmit.EDU.AU> <AD536AAB9668B76CD@mcdialb09.it.luc.edu>
  9.     <312E363C.3CDE@corp.dialog.com>
  10.     <AD53AB1396681879FA@mcdialb10.it.luc.edu>
  11.     <4h05lqINNh1t@anvil.ugrad.cs.ubc.ca>
  12. NNTP-Posting-Host: qcd.lanl.gov
  13. Mime-Version: 1.0
  14. Content-Type: text
  15. In-reply-to: c2a192@ugrad.cs.ubc.ca's message of 27 Feb 1996 15:55:38 -0800
  16.  
  17. In article <4h05lqINNh1t@anvil.ugrad.cs.ubc.ca>
  18. c2a192@ugrad.cs.ubc.ca (Kazimir Kylheku) writes:
  19.  
  20. <snip>
  21. KK:  >   foo *x;
  22. KK:  >   bar *y;
  23. KK:  >
  24. KK:  >   y=(bar *) x;
  25. KK: 
  26. KK: This is not allowed. A pointer may be converted to a void * object and back
  27. KK: _to_the_same_pointer_type_ with full recovery of the pointer. That
  28. is all that 
  29.  
  30. Wrong. That is the rule for _cast-free_ conversion. Any object
  31. (including incomplete) pointer can be _cast_ to any other object
  32. pointer _with less strict alignment_ and back, with no change.
  33.  
  34.  
  35. Cheers
  36. Tanmoy
  37. --
  38. tanmoy@qcd.lanl.gov(128.165.23.46) DECNET: BETA::"tanmoy@lanl.gov"(1.218=1242)
  39. Tanmoy Bhattacharya O:T-8(MS B285)LANL,NM87545 H:#9,3000,Trinity Drive,NM87544
  40. Others see <gopher://yaleinfo.yale.edu:7700/00/Internet-People/internet-mail>,
  41. <http://alpha.acast.nova.edu/cgi-bin/inmgq.pl>or<ftp://csd4.csd.uwm.edu/pub/
  42. internetwork-mail-guide>. -- <http://nqcd.lanl.gov/people/tanmoy/tanmoy.html>
  43. fax: 1 (505) 665 3003   voice: 1 (505) 665 4733    [ Home: 1 (505) 662 5596 ]
  44.